const defaultConfig = () => {
  const { env } = process

  return {
    db: {
      database: env.MYSQL_DATABASE,
      host: env.MYSQL_HOST,
      port: parseInt(env.MYSQL_PORT, 10) || 3306,
      username: env.MYSQL_USERNAME,
      password: env.MYSQL_PASSWORD,
      charset: env.MYSQL_CHARSET,
    },
    jwt: {
      secret: env.JWT_SECRET,
    },
  }
}

export default defaultConfig
